local skill = fk.CreateSkill{
  name = "tea__weibing_ask_skill",
}
local countNumbers = function(cards)
  local n = 0
  for _, id in ipairs(cards) do
    n = n + Fk:getCardById(id).number
  end
  return n
end
---@class ViewAsSkill
---@field hand_cards integer[]
---@field shown_cards integer[]
---@type ViewAsSkillSpec
--需要向技能中传入hand_cards与shown_cards
local weibing_ask = {
  name = "tea__weibing_ask_skill",
  mute = true,
  card_filter = function(self, player, to_select, selected)
    return table.contains(self.hand_cards, to_select)
  end,
  target_filter = Util.FalseFunc,
  view_as = function(self, player, cards)
    if countNumbers(cards) <= countNumbers(self.shown_cards) then return end
    local c = Fk:cloneCard("dilu")
    c.skillName = "tea__weibing"
    return c
  end,
}
skill:addEffect("viewas", weibing_ask)
return skill